﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using ZBJF.Warranty.Model;

namespace ZBJF.Warranty.BLL
{
    public partial class InsuranceWarrantyRecordExpressInfoService
    {
        public InsuranceWarrantyRecordExpressInfo Load(long insuranceWarrantyRecordID, byte expressSendByWhoType)
        {
            return LoadEntities(o => o.InsuranceWarrantyRecordID == insuranceWarrantyRecordID && o.ExpressSendByWhoType == expressSendByWhoType).FirstOrDefault();
        }

        public bool IsExist(long insuranceWarrantyRecordId, byte expressSendByWhoType)
        {
            return LoadEntities(o => o.InsuranceWarrantyRecordID == insuranceWarrantyRecordId && o.ExpressSendByWhoType == (byte)expressSendByWhoType).Any();
        }
    }
}
